DEF_PROJECT=../../..
include $(DEF_PROJECT)/scripts/main.mk
name=usbutils
version=006
prefix=/usr
deps+=libusb zlib
destdir=$(DIR_SYSROOT)
extdeps=eglibc-tools gcc-tools binutils-tools linux-header-tools

DL_SERV=http
DL_HOST=www.kernel.org
DL_PATH=pub/linux/utils/usb/$(name)
DL_SUFFIX=tar.bz2

cdefs+=PKG_CONFIG_LIBDIR=$(destdir)/usr/lib/pkgconfig

cflags+=--host=$(CC_TARGET)
cflags+=--build=$(CC_HOST)
cflags+=--datadir=/usr/share/misc

post-build:
	$(MAKE) -C $(if $(build),$(build),$(source)) $(iflags)
	mv -v $(DIR_SYSROOT)/usr/sbin/update-usbids.sh $(DIR_SYSROOT)/usr/sbin/update-usbids
